-- GENERATED SPELL FOR [Scholomance Handler] --


function spell0_11257(pUnit, Event) --@Arcane Blast,n/a--
pUnit:FullCastSpellOnTarget(10833,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_11257', 687, 1)
end

function spell1_11257(pUnit, Event) --@Blast Wave,Self--
pUnit:FullCastSpellOnTarget(17145,pUnit)
pUnit:RegisterEvent('Sorts_11257', 6288, 1)
end

function spell2_11257(pUnit, Event) --@Cone of Cold,Self--
pUnit:FullCastSpellOnTarget(15244,pUnit)
pUnit:RegisterEvent('Sorts_11257', 8315, 1)
end

function Sorts_11257(pUnit, Event)
local choix_sorts_11257 = math.random(0, 2)
if choix_sorts_11257 == 0 then
pUnit:RegisterEvent('spell0_11257', 1, 1)
end
if choix_sorts_11257 == 1 then
pUnit:RegisterEvent('spell1_11257', 1, 1)
end
if choix_sorts_11257 == 2 then
pUnit:RegisterEvent('spell2_11257', 1, 1)
end
end

function mob11257_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_11257', math.random(1500, 3000), 1)
end

function mob11257_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob11257_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob11257_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(11257, 1, 'mob11257_Action')
RegisterUnitEvent(11257, 2, 'mob11257_Leave')
RegisterUnitEvent(11257, 3, 'mob11257_Kill')
RegisterUnitEvent(11257, 4, 'mob11257_Die')
